package com.rdzn.mall.wx.controller;

import com.rdzn.mall.base.common.Result;
import com.rdzn.mall.wx.domain.WxCode;
import com.rdzn.mall.wx.service.IWxMinipService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.ResponseBody;

/**
 * 微信公共服务
 * Created by dingzg on 2020-11-09
 */
@Controller
@Api(tags = "WXController")
@RequestMapping("/wx")
public class WXController {

    @Autowired
    private IWxMinipService wxMinipService;

    @ApiOperation(value = "微信二维码")
    @RequestMapping(value = "/wxcode", method = RequestMethod.POST)
    @ResponseBody
    public Result getwxacodeunlimit(@RequestBody WxCode param) {
        return Result.ok(wxMinipService.getwxacodeunlimit(param));
    }

}
